import http from "@/api/http";

//获取审批通过上架了的商品展示在首页
export function getshop(pageNum,pageSize){
    return http.get('/getshop', {pageNum, pageSize})
}
//根据关键字进行模糊匹配，根据条件进行筛选
export function search(pageNum,pageSize,keyWord,xueyuan,xiaoqu){
    return http.get('/search', {pageNum, pageSize,keyWord,xueyuan,xiaoqu})
}
//获取待审批的商品
export function getapproveshop(){
    return http.get('/getapproveshop')
}
//商品通过审批
export function putshoppass(id){
    return http.put('/approveshop', {id})
}
//商品没有通过审批
export function putshopdismissal(data){
    return http.putdata('/shopdismissal', data)
}

//加入我的收藏
export function addCollection(data){
    return http.post('/addCollection', {data})
}

//删除收藏
export function deleteCollection(data){
    return http.post('/deleteCollection', {data})
}
